package com.lhj.bootdemo.designmode.factory.framework;

/**
 * @author lhj
 * @version 1.0
 * @date 2022/4/5 11:24 上午
 * @description:
 */

public abstract class Factory {

    public final  Product creat(String owner){
        Product product = creatProduct(owner);
        registerProduct(product);
        return product;
    }

    protected abstract Product creatProduct(String owner);
    protected abstract void registerProduct(Product product);

}
